//package run.siyuan.elasticsearch.repository.es;
//
//import org.springframework.data.elasticsearch.annotations.Highlight;
//import org.springframework.data.elasticsearch.annotations.HighlightField;
//import org.springframework.data.elasticsearch.annotations.Query;
//import org.springframework.data.elasticsearch.core.SearchHits;
//import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
//import run.siyuan.elasticsearch.model.Book;
//
//import java.util.List;
//
///**
// * @className: ESBookRepository
// * @Description: TODO
// * @author: siyuan
// * @date: 2022/5/30 3:29 PM
// */
//
//public interface ESBookRepository extends ElasticsearchRepository<Book, String> {
//
//    List<Book> findByTitleOrAuthor(String title, String author);
//
//    @Highlight(fields = {
//            @HighlightField(name = "title"),
//            @HighlightField(name = "author")
//    })
//    @Query("{\"match\":{\"title\":\"?0\"}}")
//    SearchHits<Book> find(String keyword);
//}
